import apibase from "@/api/apiBase";
import axios from "axios";
import { registerInterface, sendSmsInterface } from "./register.interface";

//获取验证码接口
export const $sendSms = (params: any) => {
  const $server = new apibase();
  const instance = axios.create();
  return $server.post({
    url: '/travel/api/sendSms',
    data: params,
    instance,
  });
}
//注册账号
export const $register = (params: registerInterface) => {
  const $server = new apibase();
  const instance = axios.create();
  return $server.post({
    url: '/travel/api/register',
    data: params,
    instance,
  });
}